<template>
    <div class="data-overview">
        <div class="title">数据总览</div>
        <el-row :gutter="30">
            <el-col :span="6">
                <el-card body-class="data-card" shadow="hover">
                    <div class="icon-box" style="background-color: rgba(91, 147, 255, 0.2)">
                        <el-icon :size="20" color="rgba(91, 147, 255, 1)"><Avatar /></el-icon>
                    </div>
                    <div class="content">
                        <p class="num">189+</p>
                        <p style="margin-left: 3px">用户数</p>
                    </div>
                </el-card>
            </el-col>
            <el-col :span="6">
                <el-card body-class="data-card" shadow="hover">
                    <div class="icon-box" style="background-color: rgba(255, 194, 39, 0.2)">
                        <el-icon :size="20" color="rgba(255, 194, 39, 1)"><Tickets /></el-icon>
                    </div>
                    <div class="content">
                        <p class="num">32+</p>
                        <p style="margin-left: 3px">订单数</p>
                    </div>
                </el-card>
            </el-col>
            <el-col :span="6">
                <el-card body-class="data-card" shadow="hover">
                    <div class="icon-box" style="background-color: rgba(255, 143, 107, 0.2)">
                        <el-icon :size="20" color="rgba(255, 143, 107, 1)"><GoodsFilled /></el-icon>
                    </div>
                    <div class="content">
                        <p class="num">201</p>
                        <p style="margin-left: 3px">商家数</p>
                    </div>
                </el-card>
            </el-col>
            <el-col :span="6">
                <el-card body-class="data-card" shadow="hover">
                    <div class="icon-box" style="background-color: rgba(96, 91, 255, 0.2)">
                        <el-icon :size="20" color="rgba(96, 91, 255, 1)"><Coin /></el-icon>
                    </div>
                    <div class="content">
                        <p class="num">189+</p>
                        <p style="margin-left: 3px">成交额</p>
                    </div>
                </el-card>
            </el-col>
        </el-row>
    </div>
</template>

<script lang="ts" setup></script>

<style lang="scss">
    .data-overview {
        margin-bottom: 15px;
        overflow: hidden;
        .title {
            font-size: 16px;
            font-weight: 600;
            margin-bottom: 5px;
            margin-left: 6px;
        }
    }
    .data-card {
        display: flex;
        align-items: center;
        flex: 1;
        color: #333;
        line-height: 1;
        .icon-box {
            width: 50px;
            height: 50px;
            border-radius: 50%;
            display: flex;
            align-items: center;
            justify-content: center;
            margin-right: 15px;
        }
        .content {
            font-size: 12px;
            color: #666;
            .num {
                font-size: 28px;
                font-weight: 600;
                color: #333;
                margin-bottom: 10px;
            }
        }
    }
</style>
